import request from '@/utils/request'

export function page(data) {
  return request({
    url: '/product/page',
    method: 'post',
    data
  })
}
export function save(data){
  return  request.post("/product/save",data);
}

// export function ById(id) {
//   return request({
//     url: '/product/all'+id,
//     method: 'get',
//     data
//   })
// }

export function all(data) {
  return request({
    url: '/product/all',
    method: 'get',
    data
  })
}


export function drop(id){
 // return  request.post("/depart/delete/"+id);
 return request({
   url:"/product/delete/"+id,
   method:"post",
 });
}
